<?php
class DefaultController extends BaseController
{
    public function actionIndex()
    {
        $this->layout = '/layouts/index';
        $this->render('index');
    }
    
    public function actionLanguage()
    {
        $app = Yii::app();
        $request = $app->request;
        
        $language = $request->getParam('id');
        $request->cookies[ENUM_COOKIE_LANGUAGE] = new CHttpCookie(ENUM_COOKIE_LANGUAGE, $language);
    }
}